﻿CREATE TABLE [dbo].[datUser] (
    [UserID]       INT           IDENTITY (1, 1) NOT NULL,
    [Vorname]      NVARCHAR (50) NOT NULL,
    [Nachname]     NVARCHAR (50) NOT NULL,
    [LoginName]    NCHAR (10)    NOT NULL,
    [Gesperrt]     BIT           NULL,
    [WorkingLevel] TINYINT       NULL,
    [ValidTo]      DATETIME2 (7) NULL,
    CONSTRAINT [PK_datUser] PRIMARY KEY CLUSTERED ([UserID] ASC)
);


GO
CREATE UNIQUE NONCLUSTERED INDEX [IX_datUser_LoginName]
    ON [dbo].[datUser]([LoginName] ASC);

